/***********************************************************************************
Copy right:     Coffee Tech.
Author:         jiaoyue
Version:        V1.0
Date:           2019-09
Description:    字符串处理模块
***********************************************************************************/

#ifndef STRING_OPT_H
#define STRING_OPT_H

#ifdef  STRING_OPT_C
#define STRING_OPT_EXT
#else
#define STRING_OPT_EXT extern
#endif

#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <ctype.h>

STRING_OPT_EXT int replace_first_char(char *str, char src, char dst);
STRING_OPT_EXT int strchr_index(char *str, char c);
STRING_OPT_EXT int strchr_invert(char *str, char c);
STRING_OPT_EXT int str_replace_all(char *dst, char *src, const char *oldstr, const char *newstr);
STRING_OPT_EXT int str_replace_chr_once(char *str, char oldchr, char newchr);
STRING_OPT_EXT int str_replace_chr_all(char *str, char oldchr, char newchr);
STRING_OPT_EXT int str_kick_chr_all(char *str, char chr);
STRING_OPT_EXT int str_sort(char *string[], int num);

#endif
